package com.zhengjiang.pattern.demo.singlton;



public class SingleObject1{
    private SingleObject1() {}

    private static SingleObject1 object = new SingleObject1();

    public static SingleObject1 getInstance() {
        return object;
    }

    public void methodA(){
        System.out.println("SingleObject method A");
    }

    public static void main(String[] args) {
        SingleObject1.getInstance().methodA();
    }

}
